package com.app.base.tool;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;

/**
 * 时间:2015-7-6
 * 公司:DDY
 * 作者:LBH
 * 功能:SharePreferences操作工具类
 */
public abstract class BasePager {
	
	@SuppressWarnings("unused")
	private Context context;
	private View rootView;

	public BasePager(Context context){
		this.context = context;
		
		LayoutInflater inflater =  (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
		
		rootView = initView(inflater);
	}
	
	/**
	 * 初始化View
	 * @return
	 */
	public abstract View initView(LayoutInflater inflater);
	
	/**
	 * 获取视图View
	 * @return
	 */
	public View getRootView(){
		return rootView;
	}
	
	/**
	 * 初始化数据
	 */
	public abstract void initData();
}
